package com.fmy.mcsecurity.token.model;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.concurrent.TimeUnit;

/**
 * @author Mr.fmy
 * @version 1.0.0
 * @ClassName SecurityToken
 * @Description TODO 存放token 类
 * @createTime 2019/12/9 14:55
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class SecurityToken implements Serializable {

    /**
     * 生成的token
     */
    private String token;

    /**
     * 刷新token
     */
    private String refreshToken;

    /**
     * token过期时间
     */
    private long tokenExpire;

    /**
     * 刷新token过期时间
     */
    private long refreshTokenExpire;

    /**
     * 过期时间类型
     */
    private TimeUnit timeUnit;

    /**
     * 登录时间
     */
    private LocalDateTime loginTime;
}
